<?
if (isset($_POST['observer'])) {
	$login_type = $_POST['observer'];
} else if (isset($_POST['captain'])) {
	$login_type = $_POST['captain'];
} else if (isset($_POST['player'])) {
	$login_type = $_POST['player'];
} else {
	$login_type = "unexpected";
}
$action_url = "login_".strtolower($login_type).".php";

if (isset($_GET['game'])) {
	$game_number = $_GET['game'];
	$action_url .= "?game=$game_number";
}
?>

<!DOCTYPE html>
<html>
<head>
	<meta charset="UTF-8">
	<title>히오스 밴픽 툴</title>
</head>

<body>
<div id="container" style="background-color:#FFCCCC; width:1260px; height:700px; margin: auto; vertical-align:middle;">
	<div id="login_form" style="background-color: #FFFFFF; width: 300px; margin: auto; position: relative; top: 250px;">
		<form method="post" action="<?=$action_url?>">
			<table style="width: 300px; border:0; text-align: center;">
				<tr style="height: 40px;">
					<td colspan="2"><?=$login_type?> 로그인</td>
				</tr>
				<tr style="height: 40px;">
					<td style="width: 100px; text-align: right;">비밀번호: </td>
					<td style="width: 200px; text-align: left;">
						<input type="password" name="password" size="20" maxlength="20" />
					</td>
				</tr>
				<tr style="height: 40px;">
					<td colspan="2">
						<input type="submit" name="submit" value="확인" />
					</td>
			</table>
		</form>
	</div>
</div>
</body>
</html>